<?PHP
/**
 * @Individual.php
 * Controls the model for Individual.php.
 *
 * Copyright 2011 by Matthew Wakim.  This program is part of Donate.
 * Donate is free software.  It comes with absolutely no warranty.
 * You can redistribute it and/or modify it under the terms of the GNU
 * General Public License as published by the Free Software Foundation
 * (see <http://www.gnu.org/licenses/ for more information).
 * 
 * @version April 14th 2011
 * @author Matthew Wakim, Chris Reekie
 */


class Individual {
	private $donorID; 		 // donorID int PK,FK (from auto-increment in Donor)
	private $firstName; 	 // firstname as a string
	private $lastName;  	 // lastname as a string
	

	/**
	 * Constructs an Individual instance from all attribute values.
   * @param integer $id donor ID
   * @param string $firstName first name
   * @param string $lastName last name
	 */
	function __construct($id, $firstName, $lastName)
  {
		$this->donorID = $id;
		$this->firstName = $firstName;
		$this->lastName = $lastName;		
	}
	
	/** 
   * Sets donorID.
   * @param integer $donorID donor ID
	 */
  function setdonorID($donorID) {
    $this->donorID = $donorID;
  }
	
  /** sets firstname
	*/
     function setfirstname($firstname) {
        $this->firstname = $firstname;
    }
	/** sets lastname
	*/
     function setlastname($lastname) {
        $this->lastname = $lastname;
    }
	
	/** returns the donorID
	*/
    function getDonorID(){
        return $this->donorID;
    }
	/** returns the firstname
	*/
    function getFirstName(){
        return $this->firstName;
    }
	/** returns the lastname
	*/
    function getLastName(){
        return $this->lastName;
    }
  /**
   * Prints all attributes of this object.
   * @return string $output The attributes listed in a string.
   */
  function printAllAttributes( )
  {
    $output = sprintf("first name: %s, last name: %s.", 
                      $this->firstName, $this->lastName);
    return $output;
  }
}
?>